class MigratePageShowFix < ActiveRecord::Migration
  class << self
    def up
      sobj = SystemObject.find(:first, :conditions => "name = 'Public'")
      sm = SystemMethod.find(:first, :conditions => "name = 'pages/show'")
      sm.system_object_id = sobj.id
      sm.save
    end

    def down
      sobj = SystemObject.find(:first, :conditions => "name = 'Common User Access'")
      sm = SystemMethod.find(:first, :conditions => "name = 'pages/show'")
      sm.system_object_id = sobj.id
      sm.save
    end
  end
end
